<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:f="http://xmlns.jcp.org/jsf/core">

    <ui:composition template="/template.xhtml">
        <ui:define name="title">
            <h:outputText value="#{bundle.CreateTInventoryTitle}"></h:outputText>
        </ui:define>
        <ui:define name="body">
            <h:panelGroup id="messagePanel" layout="block">
                <h:messages errorStyle="color: red" infoStyle="color: green" layout="table"/>
            </h:panelGroup>
            <h:form>
                <h:panelGrid columns="2">
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_id}" for="id" />
                    <h:inputText id="id" value="#{tInventoryController.selected.id}" title="#{bundle.CreateTInventoryTitle_id}" required="true" requiredMessage="#{bundle.CreateTInventoryRequiredMessage_id}"/>
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_unitId}" for="unitId" />
                    <h:inputText id="unitId" value="#{tInventoryController.selected.unitId}" title="#{bundle.CreateTInventoryTitle_unitId}" />
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_brand}" for="brand" />
                    <h:inputText id="brand" value="#{tInventoryController.selected.brand}" title="#{bundle.CreateTInventoryTitle_brand}" />
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_series}" for="series" />
                    <h:inputText id="series" value="#{tInventoryController.selected.series}" title="#{bundle.CreateTInventoryTitle_series}" />
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_dotNumber}" for="dotNumber" />
                    <h:inputText id="dotNumber" value="#{tInventoryController.selected.dotNumber}" title="#{bundle.CreateTInventoryTitle_dotNumber}" />
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_vendor}" for="vendor" />
                    <h:inputText id="vendor" value="#{tInventoryController.selected.vendor}" title="#{bundle.CreateTInventoryTitle_vendor}" />
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_wheelPosition}" for="wheelPosition" />
                    <h:inputText id="wheelPosition" value="#{tInventoryController.selected.wheelPosition}" title="#{bundle.CreateTInventoryTitle_wheelPosition}" />
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_purchasePrice}" for="purchasePrice" />
                    <h:inputText id="purchasePrice" value="#{tInventoryController.selected.purchasePrice}" title="#{bundle.CreateTInventoryTitle_purchasePrice}" />
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_otherPrice}" for="otherPrice" />
                    <h:inputText id="otherPrice" value="#{tInventoryController.selected.otherPrice}" title="#{bundle.CreateTInventoryTitle_otherPrice}" />
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_poNumber}" for="poNumber" />
                    <h:inputText id="poNumber" value="#{tInventoryController.selected.poNumber}" title="#{bundle.CreateTInventoryTitle_poNumber}" />
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_decomm}" for="decomm" />
                    <h:inputText id="decomm" value="#{tInventoryController.selected.decomm}" title="#{bundle.CreateTInventoryTitle_decomm}" required="true" requiredMessage="#{bundle.CreateTInventoryRequiredMessage_decomm}"/>
                    <h:outputLabel value="#{bundle.CreateTInventoryLabel_size1}" for="size1" />
                    <h:inputText id="size1" value="#{tInventoryController.selected.size1}" title="#{bundle.CreateTInventoryTitle_size1}" />
                </h:panelGrid>
                <br />
                <h:commandLink action="#{tInventoryController.create}" value="#{bundle.CreateTInventorySaveLink}" />
                <br />
                <br />
                <h:commandLink action="#{tInventoryController.prepareList}" value="#{bundle.CreateTInventoryShowAllLink}" immediate="true"/>
                <br />
                <br />
                <h:link outcome="/index" value="#{bundle.CreateTInventoryIndexLink}"/>
            </h:form>
        </ui:define>
    </ui:composition>

</html>
